<?php session_start();
validaAcesso();
echo "<h2>Cadastro de ".$_SESSION["menu"]["cad"][9]."</h2>";

require_once"funcoes/hostel_tp_documento.jsp";

if(isset($_GET[grava])==1){   
    setTpDocumento(0,$_POST["pnome"]);
}

?>

<form method="POST" action="index.jsp?grava=1&cad=9" autocomplete="off">
<div class='item'><h5>Tipo de Documento:</h5><input type="text" size="40" maxlength="40" name="pnome"> Ex: RG, CPF, Passaporte, etc</div>
<br>
<div class='item'><h5>&nbsp;</h5><input type="submit" value="cadastrar"></div>

</form>


<?php
getTpDocumento(0,"lista");
?>